Object lifetime
In object-oriented programming (OOP), object lifetime is the period of time between an object’s creation and its destruction. In some programming contexts, object lifetime coincides with the lifetime of a variable that represents the object. In other contexts – where the object is accessed by reference – object lifetime is not determined by the lifetime of a variable. For example, destruction of the variable may only destroy the reference, not the referenced object.1
Printed 2026-10-21.
(echo:: @ ᯤ)
Footnotes
-
Scott, Michael (23 March 2009). Programming Language Pragmatics (3rd ed.). Morgan Kaufmann. pp. 114–115, 120–121, 356–359. ISBN 978-0-08-092299-7. ↩